package cn.edu.suda.catalina.dataupdate.controller;

import cn.edu.suda.catalina.dataupdate.entity.UserInfo;
import cn.edu.suda.catalina.dataupdate.service.UserInfoService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 *
 * @author admin
 * @date 2017/6/22
 */
@RestController
public class UserInfoController {
    @Autowired
    private UserInfoService userInfoService;

    @RequestMapping("/userInfo")
    public String save(UserInfo userInfo) {
        return userInfoService.save(userInfo) != null ? "添加成功！" : "添加失败！";
    }

}
